package com.liujun.spring4.demo.annotation.base.demo1;

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;

/**
 * 通过该注解将PreGreetingAspect标识为一个切面
 *
 * @author liujun
 * @version 0.0.1
 * @date 2018/10/01
 */
@Aspect
public class PreGreetingAspect {

  /** 1，定义切点和增强类型 2， 增强横切逻辑 */
  @Before("execution(* greetTo(..))")
  public void beforeGreeting() {
    System.out.println("How are you?");
  }
}
